import { Modal } from "antd"
function modal(options = {}) {
    return new Promise((resolve, reject) => {
        Modal.confirm({
            content: options.content || '确认删除',
            cancelText: options.cancelText || "取消",
            okText: options.okText || "确定",
            // ...options,
            onCancel: () => {
                reject()
            },
            onOk: async () => {
                resolve()
            }
        })
    })

}


export default modal
// modal().then().catch()

